package com.china08.yxyapi.util;

public enum StudentGuardianEnum {

    // 'G0','G1','G2','G3','G4','G5','G6'
    G0("红色", "G0"), G1("绿色", "G1"), G2("白色", "G2"), G3("黄色", "G3"), G4("", "G4"), G5("", "G5"), G6("", "G6");

    private String nameNick;
    private String code;

    public static String getNameNick(String code) {
        try {
            return StudentGuardianEnum.valueOf(code).getNameNick();
        } catch (Exception exception) {
            return "";
        }
    }

    private StudentGuardianEnum(String nameNick, String code) {
        this.nameNick = nameNick;
        this.code = code;
    }

    public String getNameNick() {
        return nameNick;
    }

    public void setNameNick(String nameNick) {
        this.nameNick = nameNick;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

}
